import request from '@/utils/axiosRequest'
import useEnv from "@/hooks/useEnv";
const show = useEnv.VITE_FILE_API + "/shows?uuid="

const select = (x) => {
    return request({
        url: '/user/selectByPag?index=' + x.index + '&size=' + x.size + '&searchName=' + x.searchName + '&searchValue1=' + x.searchValue1
    })
}
const getRole = () => {
    return request({
        url: '/identity/getRole'
    })
}
const setAdmin = (id) => {
    return request({
        url: '/user/setAdmin?id=' + id
    })
}
const removeAdmin = (id) => {
    return request({
        url: '/user/removeAdmin?id=' + id
    })
}
const setStatus = (id) => {
    return request({
        url: '/user/status?id=' + id
    })
}

export default {
    select,
    getRole,
    setAdmin,
    removeAdmin,
    setStatus,
    show
}